import 'package:hellow01/model/musicData.dart';
import 'package:hellow01/tools/sqflite/sqflite_helper.dart';

class MusicSqlBll{
   addSongInfo(MusicData data)async{
       var dbClient = await SqfliteHelper.getInstance();
       var res=  dbClient.insert('music_list_table', data.toMap());
   }

   Future<List> getAllSongs() async {
    var dbClient = await SqfliteHelper.getInstance();
    var result = await dbClient.query('music_list_table', columns: ['musicName', 'singer', 'musicTotalTime', 'describe', 'nameExtension']);
    return result.toList();
  }
}